package aer.EncriptacionDeMensajes;

import java.io.BufferedReader;
import java.io.InputStreamReader;

public class EncriptacionDeMensajes {
	private static int diferencia;
	private static final char[] minusculas = { 'a', 'b', 'c', 'd', 'e', 'f', 'g', 'h', 'i', 'j', 'k', 'l', 'm', 'n',
			'o', 'p', 'q', 'r', 's', 't', 'u', 'v', 'w', 'x', 'y', 'z' };
	private static final char[] mayusculas = { 'A', 'B', 'C', 'D', 'E', 'F', 'G', 'H', 'I', 'J', 'K', 'L', 'M', 'N',
			'O', 'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W', 'X', 'Y', 'Z' };

	private static int comprobarDiferencia(char y) {
		int sol = 0;
		if (y == 112) {
		} else {
			sol = y - 112;
		}

		return sol;
	}

	private static char cambiarMin(char c) {
		for (int k = 0; k < 26; k++) {
			if (minusculas[k] == c) {
				int h = k - diferencia;
				if (h < 0) {
					h += 26;
				} else if (h > 25) {
					h -= 26;
				}

				c = minusculas[h];
				k = 27;
			} // fin if
		}

		return c;
	}

	private static char cambiarMay(char c) {
		for (int k = 0; k < 26; k++) {
			if (mayusculas[k] == c) {
				int h = k - diferencia;
				// System.out.println("h: "+h);
				if (h < 0) {
					h += 26;
				} else if (h > 25) {
					h -= 26;
				}

				c = mayusculas[h];
				k = 27;
			} // fin if
		}

		return c;
	}

	private static String reconstruir(String linea, int lon) {
		String nuevo = "";
		for (int j = 0; j < lon; j++) {
			char c = linea.charAt(j);
			if (c >= 97 && c <= 122) { // minusculas
				c = cambiarMin(c);
			} else if (c >= 65 && c <= 90) { // mayusculas
				c = cambiarMay(c);
			}
			// no es una letra
			nuevo += c;
		}

		return nuevo;
	}

	private static int contarVocales(String linea, int lon) {
		int acc = 0;
		for (int i = 1; i < lon; i++) {
			char c = linea.charAt(i);
			if (c == 'a' || c == 'e' || c == 'i' || c == 'o' || c == 'u' || c == 'A' || c == 'E' || c == 'I'
					|| c == 'O' || c == 'U') {
				acc++;
			}
		}

		return acc;
	}

	public static void main(String[] args) throws Exception {
		boolean b = true;
		BufferedReader br = new BufferedReader(new InputStreamReader(System.in));

		while (b) {
			String linea = br.readLine();
			int lon = linea.length();
			diferencia = comprobarDiferencia(linea.charAt(0));
			int vocales = -1;
			if (diferencia == 0) {
				vocales = contarVocales(linea, lon);
			} else {
				linea = reconstruir(linea, lon);
				vocales = contarVocales(linea, lon);
			} // fin else
			if (linea.equals("pFIN")) {
				b = false;
			} else {
				System.out.print(vocales + "\n");
			}
		} // fin while

	} // fin main

}